package com.zlt.bkparking.mapper;

import com.zlt.bkparking.dto.BusinessUserDTO;
import com.zlt.bkparking.entity.BackUser;
import com.zlt.bkparking.entity.BackUserExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

@Repository
public interface BackUserMapper {
    long countByExample(BackUserExample example);

    int deleteByExample(BackUserExample example);

    int deleteByPrimaryKey(Long buId);

    int insert(BackUser record);

    int insertSelective(BackUser record);

    int insertSelectiveReturnKey(BackUser record);

    List<BackUser> selectByExample(BackUserExample example);

    BackUser selectByPrimaryKey(Long buId);

    int updateByExampleSelective(@Param("record") BackUser record, @Param("example") BackUserExample example);

    int updateByExample(@Param("record") BackUser record, @Param("example") BackUserExample example);

    int updateByPrimaryKeySelective(BackUser record);

    int updateByPrimaryKey(BackUser record);

    int insertUserRole(Long buId, Integer roleId);

    long countByBusinessUserDTOByRole(@Param("bd") BusinessUserDTO businessUserDTO, @Param("rid") Integer rid);

    List<BackUser> selectByExampleByRole(@Param("bd")BusinessUserDTO businessUserDTO, @Param("rid")Integer rid);

}